<?php

use Illuminate\Http\Request;

/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/

Route::middleware('auth:api')->get('/user', function (Request $request) {
    return $request->user();
});
Route::any('/user', 'UserController@store');//save user info
Route::post('/get_user_info', 'UserController@show');//get user info
Route::post('/update_user_info', 'UserController@update');//update user info
Route::post('/get_brand_list_by_input', 'BrandsController@getBrandsByInput');//get brand by input
Route::post('/get_brand_list_all', 'BrandsController@getBrandsAll');// get all brands
Route::post('/create_brand', 'BrandsController@create');//create new brands
Route::post('/get_brand_by_name', 'BrandsController@getBrandByName');// get brand by name
Route::post('/assessment_file_upload', 'CustomerExperienceAssessmentController@assessmentFileUpload');// upload image
Route::post('/assessment_item_save', 'CustomerExperienceAssessmentController@assessmentItemSave');//save AS info
Route::post('/assessment_get_item_by_name', 'CustomerExperienceAssessmentController@assessmentGetItemByName');//get AS by name
Route::post('/friction_evaluation_save', 'FrictionEvaluationController@save');//save frinction evaluation
Route::post('/friction_evaluation_final_save', 'BrandsController@makeBrandNotEditable');//make the brand can not be changed
Route::post('/get_current_brand_info', 'BrandsController@getCurrentBrandInfo');//get brand by input
Route::post('/get_as_info_by_user', 'BrandsController@getAssessmentInfoByUser');//get current user assessmnets info
Route::post('/get_as_info_by_current_user_brand', 'CustomerExperienceAssessmentController@getAssessmentInfoByCurrentUserBrand');//get current user assessmnets info
Route::post('/agree_save', 'CustomerExperienceAssessmentController@agreeSave');
Route::post('/disagree_save', 'CustomerExperienceAssessmentController@disagreeSave');
Route::post('/share_friction_evaluation_save', 'FrictionEvaluationController@sharePageItemSave');//save frinction evaluation
Route::post('/get_as_info_by_user_brand', 'CustomerExperienceAssessmentController@getAssessmentInfoByUserBrand');//get share page user assessmnets info
Route::post('/share_friction_evaluation_final_save', 'BrandsController@shareFrictionEvaluationFinalSave');